package com.ruoyi.msg.domain.bo;

import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.common.core.validate.AddGroup;
import com.ruoyi.common.core.validate.EditGroup;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 消息推送业务对象 msg_push
 *
 * @author xiaohao
 * @date 2023-02-01
 */

@Data
@EqualsAndHashCode(callSuper = true)
public class MsgPushBo extends BaseEntity {

    /**
     * 主键
     */
    @NotNull(message = "主键不能为空", groups = {EditGroup.class})
    private Long id;

    /**
     * 消息接收者姓名
     */
    @NotNull(message = "消息接收者姓名不能为空", groups = {AddGroup.class, EditGroup.class})
    private Long appointorId;

    @NotNull(message = "消息目标人员类型", groups = {AddGroup.class, EditGroup.class})
    private String targetType;

    /**
     * 标题
     */
    @NotBlank(message = "标题不能为空", groups = {AddGroup.class, EditGroup.class})
    private String title;

    /**
     * 内容
     */
    @NotBlank(message = "内容不能为空", groups = {AddGroup.class, EditGroup.class})
    private String content;

    /**
     * 推送类型
     */
    @NotBlank(message = "推送类型不能为空", groups = {AddGroup.class, EditGroup.class})
    private String type;

    /**
     * 推送状态
     */
    @NotBlank(message = "推送状态不能为空", groups = {AddGroup.class, EditGroup.class})
    private String status;

    /**
     * 是否读取
     */
    private String readFlag;


}
